package com.itheima.manager;

import com.itheima.common.R;
import com.itheima.domain.PrefrenceArea;
import com.itheima.service.IPrefrenceAreaService;
import org.apache.dubbo.config.annotation.DubboReference;
import org.apache.dubbo.config.annotation.DubboService;
import org.springframework.stereotype.Component;

import java.util.List;

@Component
public class CmsPrefrenceAreaManager {

    @DubboReference
    IPrefrenceAreaService prefrenceAreaService;

    public R getAll() {
        List<PrefrenceArea> all = prefrenceAreaService.findAll();
        return R.success(all);
    }
}
